﻿@{
    Layout = null;
}
@using LY.Manage.Model;
@model LY.Manage.Model.Technical


<!DOCTYPE html>

<head>
    <meta name="viewport" content="width=device-width" />

    <title>详细</title>
    <!--引入文件-->
    <link href="~/Content/themes/default/easyui.css" rel="stylesheet" />
    <link href="~/Content/themes/icon.css" rel="stylesheet" />
    <script src="~/Scripts/jquery-1.8.2.min.js"></script>
    <script src="~/Scripts/jquery.easyui.min.js"></script>
    <script src="~/Scripts/easyui-lang-zh_CN.js"></script>
    <script src="~/Scripts/datapattern.js"></script>
    <script src="~/Scripts/jquery.unobtrusive-ajax.min.js"></script>
    <script src="~/Scripts/jquery.validate.min.js"></script>
    <link href="~/Content/BaseStyle.css" rel="stylesheet" />
    <script src="~/My97DatePicker/WdatePicker.js"></script>


    <script type="text/javascript">

        //获取url中的参数
        function getUrlParam(name) {
            var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)"); //构造一个含有目标参数的正则表达式对象
            var r = window.location.search.substr(1).match(reg);  //匹配目标参数
            if (r != null) return unescape(r[2]); return null; //返回参数值
        }
        $(function () {
            console.log("001页面载入!");

            $('#id').val(getUrlParam("idzhi"));



            console.log(getUrlParam("idzhi"));
            var pars = {
                objectId: getUrlParam("idzhi")
            };

        });

        function showyemian(yemianid) {
            $('#id').val(getUrlParam("idzhi"));
            var id = $('#id').val();

            // alert(id);
            //给IFrame指定页面URL
            $("#addFrame").attr("src", "/ErweiMa/Xiangxi" + "?idzhi=" + id + "&yemianid=" + yemianid);
            $("#addDiv").css("display", "block");
            $('#addDiv').dialog({
                title: '详细信息',
                width: 380,
                height: 330,
                collapsible: true,
                maximizable: true,
                maximized: true,
                resizable: true,
                modal: true,
                buttons: [{
                    text: '关闭',
                    handler: function () {
                        $('#addDiv').dialog('close');
                    }
                }]
            });

        }

        function afterAdd() {

            $('#addDiv').dialog('close');   //关闭dialog
            $('#showDiv').datagrid('reload');//加载表格不会跳到第一页。


        }

    </script>
</head>
<body>

    @using (Ajax.BeginForm("EditInfo", "Technical", new { }, new AjaxOptions()
{
    HttpMethod = "post",
    OnSuccess = "afterEdit"
}, new { id = "fmMain" }))
    {
        @Html.AntiForgeryToken()
        @Html.ValidationSummary(true)
        <input type="hidden" id="id" name="id" />
        <table>
            <tr>
                <td><div style="width:100%;font-size:22px; color:red; text-align:center">@ViewBag.tixinginfo </div></td>
            </tr>


            <tr> <td>设备名称:@ViewBag.mingcheng </td></tr>
            <tr> <td>单位:@ViewBag.danwei </td></tr>
            <tr>
                <td>所在地点:@ViewBag.suozaididian </td>
            </tr>
            <tr>  <td>编号:@ViewBag.bianhao</td></tr>



            @if (@ViewBag.tixing <= 30)
            {
                <tr>
                    <td>
                        <font size="3" color="red">
                            @ViewBag.tixinginfo
                        </font>
                    </td>
                </tr>
            }
            <tr>

                <td>
                    <a href="#" onclick="showyemian(1)">   1、技术规格说明</a>
                </td>
            </tr>
            <tr>

                <td>
                    <a href="#" onclick="showyemian(2)">   2、调动记录</a>
                </td>
            </tr>
            <tr>

                <td>
                    <a href="#" onclick="showyemian(3)">    3、事故记录</a>
                </td>
            </tr>
            <tr>

                <td>
                    <a href="#" onclick="showyemian(4)">    4、检修记录</a>
                </td>
            </tr>
            <tr>

                <td>
                    <a href="#" onclick="showyemian(5)">    5、中大修记录</a>
                </td>
            </tr>
            <tr>

                <td>
                    <a href="#" onclick="showyemian(6)">   6、技术鉴定验收记录</a>
                </td>
            </tr>
            <tr>

                <td>
                    <a href="#" onclick="showyemian(7)">   7、工作记录</a>
                </td>
            </tr>
            <tr>

                <td>
                    <a href="#" onclick="showyemian(8)">    8、其它事项记录</a>
                </td>
            </tr>
        </table>
          <!--添加数据-->
        <div id="addDiv" style="display:none; overflow:hidden;">
            <iframe id="addFrame" style="width:100%;height:100%;" frameborder="0" scrolling="auto"></iframe>
        </div>

    }
</body>